#include<string.h>
#include<iostream>
using namespace std;
char v1[100],v2[100],prod[10000][2];
int n1,n2,prod_s;
void citire_vector();
void afisare_vector();
void produs();
int main()
{
    citire_vector();
    produs();
    afisare_vector();
    return 0;
}

void citire_vector()
{
    cout<<"cate elemente are v1??? "<<endl;
    cin>>n1;
    cout<<"introduceti elementele vectorului: "<<endl;
    for(int i=0;i<n1;++i)
         cin>>v1[i];

    cout<<"cate elemente are v2??? "<<endl;
    cin>>n2;
    cout<<"introduceti elementele vectorului: "<<endl;
    for(int i=0;i<n2;++i)
         cin>>v2[i];

}

void afisare_vector()
{
    for(int i=0;i<prod_s;++i)
        cout<<prod[i][0]<<" x "<<prod[i][1]<<endl;
}

void produs()
{
    for(int i=0;i<n1;++i)
    for(int j=0;j<n2;++j)
    {
        prod[prod_s][0]=v1[i];
        prod[prod_s++][1]=v2[j];
    }
}
